package com.acme.domain;

import java.util.HashSet;
import java.util.Set;


public class Parent extends AbstractPersistentObject {
	private String name;
	private Set<Child> children = new HashSet<Child>(); 
	
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public Set<Child> getChildren() {
		return children;
	}
	public void setChildren(Set<Child> children) {
		this.children = children;
	}
	
	public void addChild(Child child) {
		child.setParent(this);
		children.add(child);
	}
}
